import { Component } from 'react'
import { Routes, Route, Navigate } from 'react-router-dom'
import Vnan from '../common/vnan'
import Home from '../views/home'
import Cart from '../views/cart'
import Cate from '../views/cate'
import Mine from '../views/mine'
class Index extends Component {
  constructor () {
    super()
  }
  render () {
    return (
      <div>
        <Vnan></Vnan>
        <Routes>
          <Route path='home' element={<Home></Home>}></Route>
          <Route path='cart' element={<Cart></Cart>}></Route>
          <Route path='cate' element={<Cate></Cate>}></Route>
          <Route path='mine' element={<Mine></Mine>}></Route>
          <Route path='' element={<Navigate to='home'></Navigate>}></Route>
        </Routes>
      </div>
    )
  }
}
export default Index
